package com.cadre.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.cadre.dao.LetterMapper;
import com.cadre.entity.Letter;
import com.cadre.entity.User;

@Service
@Transactional
public class LetterServiceImpl {
	 @Autowired
	  private LetterMapper letterMapper;
	 
	 //添加写信信息
	 public boolean addLetter(Letter letter){
		return letterMapper.addLetter(letter);
	 }
	 
	/*public List<Letter> SelectLetter(){
		return this.letterMapper.SelectLetter();
		
	}*/
	 
	 /*
	  * 遍历所有信件
	  */
	 public List<Letter> selectAllLetter(){
		 return this.letterMapper.selectAllLetter();
	 }
	 
	 
	 
}
